﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace TestCoupon.Model
{
    public class CouponRequest : MyWeb.API.Common.BaseRequestModel<CouponResponse>
    {
        public int BatchId { get; set; }
        public override string ApiName
        {
            get { return "api/coupon/GetCouponBatch"; }
        }

        public override void Validate()
        {
            if (BatchId <= 0)
            {
                throw new MyWeb.API.Common.ExceptionCustomize("400", "参数错误");
            }
        }
    }

    public class CouponListsRequest : MyWeb.API.Common.BaseRequestModel<CouponListsResponse>
    {
        public override bool HttpGet
        {
            get
            {
                return false;
            }
        }
        public override string ApiName
        {
            get { return "api/couponbatch/GetCouponBatchList"; }
        }
    }

    public class CouponListRequest : MyWeb.API.Common.BaseRequestModel<CouponListResponse>
    {
        public List<int> BatchIds { get; set; }
        public override bool HttpGet
        {
            get
            {
                return false;
            }
        }
        public override string ApiName
        {
            get { return "api/coupon/GetCouponBatchs"; }
        }
    }
}
